package routers

import (
	"SuNing/controllers"
	beego "github.com/beego/beego/v2/server/web"
)

func init() {
	beego.Router("/", &controllers.MainController{})

	beego.Router("/login", &controllers.UserControllers{}, "post:Login")

	beego.Router("/adds", &controllers.GoodsController{}, "post:Adds")
	beego.Router("/upload", &controllers.GoodsController{}, "post:Upload")
	beego.Router("/update", &controllers.GoodsController{}, "post:Update")
	beego.Router("/list", &controllers.GoodsController{}, "get:List")
	beego.Router("/show", &controllers.GoodsController{}, "get:Show")
	beego.Router("/page", &controllers.GoodsController{}, "get:Page")
	beego.Router("/del", &controllers.GoodsController{}, "get:Del")
	beego.Router("/rank", &controllers.GoodsController{}, "get:GoodsRank")
}
